package cn.tsoft.remoting
{
	import cn.tsoft.AbstractResponder;
	
	import flash.utils.setTimeout;

	public class SyncResponder extends AbstractResponder
	{
		
		
		private var _delay:Number ; 
		
		public function SyncResponder(defaultFaultListener:Function=null,delay:Number=1)
		{
			super(defaultFaultListener);
			if(delay<1) throw new Error("错误");
			_delay = delay;
		}
		
		public function invokeResult(data:Object):void{
			setTimeout(super.notifyResultListeners,1,data);
		}
		
		
		public function invokeFault(info:Object):void{
			setTimeout(super.notifyFaultListeners(,1,info);
		}
		
	}
}